
<!DOCTYPE html>
<html lang="en" class="loading">
<head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
    <meta name="viewport" content="width=device-width, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no">
    <title>weifan</title>
    <meta name="apple-mobile-web-app-capable" content="yes" />
    <meta name="apple-mobile-web-app-status-bar-style" content="black-translucent">
    <meta name="google" content="notranslate" />
    <meta name="keywords" content="TriDiamond Obsidian,"> 
    
    <meta name="author" content="weifan"> 
    <link rel="alternative" href="atom.xml" title="weifan" type="application/atom+xml"> 
    <link rel="icon" href="/img/favicon.png"> 
    <link href="https://fonts.loli.net/css?family=Roboto+Mono|Rubik&display=swap" rel="stylesheet">
    
<link rel="stylesheet" href="//at.alicdn.com/t/font_1429596_nzgqgvnmkjb.css">

    
<link rel="stylesheet" href="//cdn.bootcss.com/animate.css/3.7.2/animate.min.css">

    
<link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/social-share.js/1.0.16/css/share.min.css">

    
<link rel="stylesheet" href="//cdn.bootcss.com/codemirror/5.48.4/codemirror.min.css">

    
<link rel="stylesheet" href="//cdn.bootcss.com/codemirror/5.48.4/theme/dracula.css">

    
<link rel="stylesheet" href="/css/obsidian.css">

    
<link rel="stylesheet" href="/css/ball-atom.min.css">

<meta name="generator" content="Hexo 4.2.1"></head>


<body class="loading">
    <div class="loader">
        <div class="la-ball-atom la-2x">
            <div></div>
            <div></div>
            <div></div>
            <div></div>
        </div>
    </div>
    <span id="config-title" style="display:none">weifan</span>
    <div id="loader"></div>
    <div class="nav">
    <ul id="menu-menu" class="menu">
        
        <li class="animated fadeInDown menu-item menu-item-type-post_type menu-item-object-page">
            <a href="/whoami/" title="ABOUT" external="false">ABOUT</a>
        </li>
        
        <li class="animated fadeInDown menu-item menu-item-type-post_type menu-item-object-page">
            <a href="/categories/" title="CATEGORIES" external="false">CATEGORIES</a>
        </li>
        
        <li class="animated fadeInDown menu-item menu-item-type-post_type menu-item-object-page">
            <a href="/tags/" title="TAGS" external="false">TAGS</a>
        </li>
        
        <li class="animated fadeInDown menu-item menu-item-type-post_type menu-item-object-page">
            <a href="/archives/" title="ARCHIVES" external="false">ARCHIVES</a>
        </li>
        
    </ul>
    <p class="copyright" id="copyright">
        &copy; 2020 weifan.
        Powered by <a href="http://hexo.io/" title="Hexo" target="_blank" rel="noopener">Hexo</a>
        Theme <a href="https://github.com/TriDiamond/hexo-theme-obsidian" title="Obsidian" target="_blank" rel="noopener">Obsidian</a>
    </p>
</div>

<div id="container">
    
<div class="search-box">
    <form class="site-search-form">
        <span class="iconfont icon-search"></span>
        <input type="text" id="local-search-input" class="st-search-input" />
        <div class="iconfont icon-cross search-box-close"></div>
    </form>
    <div class="search-scrollable">
        <div id="local-search-result" class="local-search-result-cls" data-initialise="Initialising search index..."
            data-start="Please input search keywords." data-empty="No result found, please try other keywords.">
            <span>Please input search keywords.</span>
        </div>
    </div>
</div>
<div id="header">
    <div>
        <div class="logo animated fadeInDown">
            <img src="/img/favicon.png" alt="">
            <a class="image-logo" href="/"></a>
        </div>
        <ul id="menu-menu" class="menu text-menu">
            
            <li class="animated fadeInDown menu-item menu-item-type-post_type menu-item-object-page">
                <a href="/whoami/" title="ABOUT" external="false" class="menu-link">ABOUT</a>
            </li>
            
            <li class="animated fadeInDown menu-item menu-item-type-post_type menu-item-object-page">
                <a href="/categories/" title="CATEGORIES" external="false" class="menu-link">CATEGORIES</a>
            </li>
            
            <li class="animated fadeInDown menu-item menu-item-type-post_type menu-item-object-page">
                <a href="/tags/" title="TAGS" external="false" class="menu-link">TAGS</a>
            </li>
            
            <li class="animated fadeInDown menu-item menu-item-type-post_type menu-item-object-page">
                <a href="/archives/" title="ARCHIVES" external="false" class="menu-link">ARCHIVES</a>
            </li>
            
            
            <li class="animated fadeInDown search-bar iconfont icon-search"></li>
            
        </ul>
        <div class="iconfont icon-menu switchmenu gradient-text animated fadeInDown"></div>
    </div>
</div>
<div id="screen">
    <div id="mark">
        <div class="cover animated fadeIn" style="
            animation-delay: 900ms;
            animation-duration: 2.8s;
            background-image:
                radial-gradient(ellipse closest-side, rgba(0, 0, 0, 0.56), #100e17),
                url(/img/cover.jpg);">
        </div>
    </div>
    
    <div id="post0" class="else">
        <p class="animated fadeInDown">
            
            <a href="/categories/算法"><b>「
                </b>算法<b> 」</b></a>
            
            June 14, 2020
        </p>
        <h3 class="post-title animated fadeInDown">
            <a href="/2020/06/14/%E5%9B%9E%E6%9C%94/" title="回朔" class="posttitle">回朔</a></h3>
        
        <p class="post-count animated fadeInDown">
            
            <span>
                <b class="iconfont icon-text2"></b> <i>Words count</i>
                5.4k
            </span>
            
            
            <span>
                <b class="iconfont icon-timer__s"></b> <i>Reading time</i>
                5 mins.
            </span>
            
            
        </p>
        
        
        <ul class="animated fadeInDown post-tags-list" itemprop="keywords"><li class="animated fadeInDown post-tags-list-item"><a class="animated fadeInDown post-tags-list-link" href="/tags/%E7%AE%97%E6%B3%95/" rel="tag">算法</a></li></ul>
        
        <div class="md-content animated fadeIn">
            
            <p>回溯算法实际上一个类似枚举的搜索尝试过程，主要是在搜索尝试过程中寻找问题的解，当发现已不满足求解条件时，就 “回溯” 返回，尝试别的路径。回溯法是一种选优搜索法，按选优条件向前搜索，以达到目标。但当探...</p>
            
            <span class="read-more"><a href="/2020/06/14/%E5%9B%9E%E6%9C%94/" title="Read article" class="posttitle">Read article</a>
                <b class="iconfont icon-arrow-right- gradient-text"></b></span>
        </div>
    </div>
    
</div>

<div class="screen-gradient-after">
    <div class="screen-gradient-content">
        <div class="screen-gradient-content-inside">
            <div class="bold-underline-links screen-gradient-sponsor">
                <p>
                    <span class="typed-text"></span>
                </p>
            </div>
        </div>
    </div>
</div>

    <div id="primary">
        
<div class="post" id="post">
    <div class="post-cover animated fadeIn" style="
            background-image:
            radial-gradient(ellipse closest-side, rgba(0, 0, 0, 0.65), #100e17),
            url(/img/welcome-cover.jpg);">
    </div>
    <div class="else">
        <p class="animated fadeInDown">
            
                <a href="/categories/算法">
                  <b>「 </b>算法<b> 」</b>
                </a>
            
            June 08, 2020
        </p>
        <h3 class="post-title animated fadeInDown"><a href="/2020/06/08/%E5%8A%A8%E6%80%81%E8%A7%84%E5%88%92/" title="动态规划" class="posttitle">动态规划</a></h3>
        
            <p class="post-count animated fadeInDown">
                
                    <span>
                        <b class="iconfont icon-text2"></b> <i>Words count</i>
                        12k
                    </span>
                
                
                    <span>
                        <b class="iconfont icon-timer__s"></b> <i>Reading time</i>
                        11 mins.
                    </span>
                
                
            </p>
            
                <ul class="animated fadeInDown post-tags-list" itemprop="keywords"><li class="animated fadeInDown post-tags-list-item"><a class="animated fadeInDown post-tags-list-link" href="/tags/%E7%AE%97%E6%B3%95/" rel="tag">算法</a></li></ul>
            
        
        <div class="md-content animated fadeIn">
            
                <p><strong>动态规划与分治法类似，都是把大问题拆分成小问题，通过寻找大问题与小问题的递推关系，解决一个个小问题，最终达到解决原问题的效果。但不同的是，分治法在子问题和子子问题等上被重复计算了很多次，而动态规划则具有记忆性，通过填写表把所有已经解决的子问题答案纪录下来，在新问题里需要用到的子问题可以直接提取，避免了重复计算，从而节约了时间，所以在问题满足最优性原理之后，用动态规划解决问题的核心就在于填表，表填写完毕，最优解也就找到。</strong></p>
<blockquote>
<p>采用动态规划，必须要知道初始状态和状态转移方程。</p>
</blockquote>
<p><strong>给定不同面额的硬币和一...</strong></p>
            
            <span class="read-more"><a href="/2020/06/08/%E5%8A%A8%E6%80%81%E8%A7%84%E5%88%92/" title="Read article" class="posttitle">Read article</a> <b class="iconfont icon-arrow-right- gradient-text"></b></span>
        </div>
    </div>
</div>


<div class="post" id="post">
    <div class="post-cover animated fadeIn" style="
            background-image:
            radial-gradient(ellipse closest-side, rgba(0, 0, 0, 0.65), #100e17),
            url(/img/welcome-cover.jpg);">
    </div>
    <div class="else">
        <p class="animated fadeInDown">
            
                <a href="/categories/Linux">
                  <b>「 </b>LINUX<b> 」</b>
                </a>
            
            June 07, 2020
        </p>
        <h3 class="post-title animated fadeInDown"><a href="/2020/06/07/Linux/" title="Linux" class="posttitle">Linux</a></h3>
        
            <p class="post-count animated fadeInDown">
                
                    <span>
                        <b class="iconfont icon-text2"></b> <i>Words count</i>
                        9.7k
                    </span>
                
                
                    <span>
                        <b class="iconfont icon-timer__s"></b> <i>Reading time</i>
                        9 mins.
                    </span>
                
                
            </p>
            
                <ul class="animated fadeInDown post-tags-list" itemprop="keywords"><li class="animated fadeInDown post-tags-list-item"><a class="animated fadeInDown post-tags-list-link" href="/tags/Linux/" rel="tag">Linux</a></li></ul>
            
        
        <div class="md-content animated fadeIn">
            
                

<ul>
<li><a href="#shell">Shell</a><ul>
<li><a href="#脚本">脚本</a></li>
<li>[Shell　输入/输出重定向](#shell　输入-输出重定向)</li>
</ul>
</li>
<li><a href="#查询系统负载信息">查询系统负载信息</a></li>
<li><a href="#useful-commands">Useful commands</a><ul>
<li><a href="#wc">wc</a></li>
<li><a href="#ps">ps</a></li>
<li><a href="#top">top</a></li>
<li><a href="#free">free</a></li>
<li><a href="#df">df</a></li>
</ul>
</li>
</ul>

<h3 id="脚本"><a href="#脚本" class="headerlink" title="脚本"></a>脚本</h3><pre><code class="shell">echo -e &quot;OK! \n&quot; # -e 开启转义</code></pre>
<pre><code class="shell">echo &quot;数组元素个数为: ${#my_array[*]}&quot;
echo &quot;数组元素个数为: ${#my_array[@]}&quot;</code></pre>
<ul>
<li>拼接字符串</li>
</ul>
<pre><code class="shell">your_name=&quot;runoob&quot...</code></pre>
            
            <span class="read-more"><a href="/2020/06/07/Linux/" title="Read article" class="posttitle">Read article</a> <b class="iconfont icon-arrow-right- gradient-text"></b></span>
        </div>
    </div>
</div>


<div class="post" id="post">
    <div class="post-cover animated fadeIn" style="
            background-image:
            radial-gradient(ellipse closest-side, rgba(0, 0, 0, 0.65), #100e17),
            url(/img/welcome-cover.jpg);">
    </div>
    <div class="else">
        <p class="animated fadeInDown">
            
                <a href="/categories/DataStructure">
                  <b>「 </b>DATASTRUCTURE<b> 」</b>
                </a>
            
            June 07, 2020
        </p>
        <h3 class="post-title animated fadeInDown"><a href="/2020/06/07/DataStructure/" title="DataStructure" class="posttitle">DataStructure</a></h3>
        
            <p class="post-count animated fadeInDown">
                
                    <span>
                        <b class="iconfont icon-text2"></b> <i>Words count</i>
                        1.8k
                    </span>
                
                
                    <span>
                        <b class="iconfont icon-timer__s"></b> <i>Reading time</i>
                        2 mins.
                    </span>
                
                
            </p>
            
                <ul class="animated fadeInDown post-tags-list" itemprop="keywords"><li class="animated fadeInDown post-tags-list-item"><a class="animated fadeInDown post-tags-list-link" href="/tags/DataStructure/" rel="tag">DataStructure</a></li></ul>
            
        
        <div class="md-content animated fadeIn">
            
                

<ul>
<li><a href="#二叉树">二叉树</a><ul>
<li><a href="#遍历">遍历</a></li>
</ul>
</li>
<li><a href="#排序">排序</a></li>
</ul>


<h3 id="遍历"><a href="#遍历" class="headerlink" title="遍历"></a>遍历</h3><ul>
<li>已知先序和后序，不能唯一确定二叉树</li>
<li>已知先序或后序，而又知中序，则能唯一确定二叉树</li>
<li>先序、中序相同时，二叉树没有左子树</li>
<li>后序、中序相同时，二叉树没有右子树</li>
<li>后序、先序相同时，只有一个根节点</li>
</ul>
<table>
<thead>
<tr>
<th>排序方法</th>
<th>时间复杂度（平均）</th>
<th>时间复杂度（最坏)</th>
<th>时间复杂度（最好)</th>
<th>空间复杂度</th>
<th>稳定性</th>
<th>复杂性</th>
</tr>
</thead>
<tbody><tr>
<td>直接插入排序</td>
<td>O(n2)</td>
<td>O(n2)</td>
<td>O(n)</td>
<td>O(1)</td>
<td>稳定</td>
<td>简单</td>
</tr>
<tr>
<td>希尔排序</td>
<td>O(nlog2n)</td>
<td>O(n2)</td>
<td>O(n)</td>
<td>O(1)</td>
<td>不稳定</td>
<td>较复杂</td>
</tr>
<tr>
<td>直接...</td></tr></tbody></table>
            
            <span class="read-more"><a href="/2020/06/07/DataStructure/" title="Read article" class="posttitle">Read article</a> <b class="iconfont icon-arrow-right- gradient-text"></b></span>
        </div>
    </div>
</div>


<div class="post" id="post">
    <div class="post-cover animated fadeIn" style="
            background-image:
            radial-gradient(ellipse closest-side, rgba(0, 0, 0, 0.65), #100e17),
            url(/img/welcome-cover.jpg);">
    </div>
    <div class="else">
        <p class="animated fadeInDown">
            
                <a href="/categories/Database">
                  <b>「 </b>DATABASE<b> 」</b>
                </a>
            
            June 07, 2020
        </p>
        <h3 class="post-title animated fadeInDown"><a href="/2020/06/07/Database/" title="Database" class="posttitle">Database</a></h3>
        
            <p class="post-count animated fadeInDown">
                
                    <span>
                        <b class="iconfont icon-text2"></b> <i>Words count</i>
                        12k
                    </span>
                
                
                    <span>
                        <b class="iconfont icon-timer__s"></b> <i>Reading time</i>
                        11 mins.
                    </span>
                
                
            </p>
            
                <ul class="animated fadeInDown post-tags-list" itemprop="keywords"><li class="animated fadeInDown post-tags-list-item"><a class="animated fadeInDown post-tags-list-link" href="/tags/Database/" rel="tag">Database</a></li></ul>
            
        
        <div class="md-content animated fadeIn">
            
                

<ul>
<li><a href="#关系型数据库和非关系型数据库">关系型数据库和非关系型数据库</a><ul>
<li><a href="#关系数据库">关系数据库</a></li>
<li><a href="#非关系型数据库">非关系型数据库</a></li>
<li><a href="#对比">对比</a></li>
</ul>
</li>
<li><a href="#redis">redis</a><ul>
<li><a href="#redis持久化">redis持久化</a><ul>
<li><a href="#rdb持久化">RDB持久化</a></li>
<li><a href="#aof持久化">AOF持久化</a></li>
<li><a href="#优缺点">优缺点</a></li>
</ul>
</li>
</ul>
</li>
<li><a href="#mysql">Mysql</a><ul>
<li><a href="#主键">主键</a></li>
<li><a href="#引擎">引擎</a></li>
<li><a href="#索引">索引</a><ul>
<li><a href="#分类">分类</a></li>
<li><a href="#索引原理">索引原理</a></li>
<li><a href="#聚集索引和非聚集索引">聚集索引和非聚集索引</a></li>
<li><a href="#正确使用索引">正确使用索引</a></li>
</ul>
</li>
</ul>
</li>
</ul>


<h3 id="关系数据库"><a href="#关系数据库" class="headerlink" title="关系数据库"></a>关系数据库</h3><blockquote>
<p>由二维表及其之间的联系组成的一个数据组织。</p>
</blockquote>
<ul>
<li><strong>关系</strong>：一张二维表，每个关系都具有一个关系名，即<strong>表名</strong>。</li>
<li><strong>元祖</strong>：二维表中的一行，在数据库中被称为<strong>记录</strong>。</li>
<li><strong>属性</strong>：二维表中的一列，在数据库中被称为<strong>字段</strong>。</li>
<li><strong>域</strong>　：属性的取值范围，也就是数据库中某一列的取值限制。...</li></ul>
            
            <span class="read-more"><a href="/2020/06/07/Database/" title="Read article" class="posttitle">Read article</a> <b class="iconfont icon-arrow-right- gradient-text"></b></span>
        </div>
    </div>
</div>


<div class="post" id="post">
    <div class="post-cover animated fadeIn" style="
            background-image:
            radial-gradient(ellipse closest-side, rgba(0, 0, 0, 0.65), #100e17),
            url(/img/welcome-cover.jpg);">
    </div>
    <div class="else">
        <p class="animated fadeInDown">
            
                <a href="/categories/Computer">
                  <b>「 </b>COMPUTER<b> 」</b>
                </a>
            
            June 07, 2020
        </p>
        <h3 class="post-title animated fadeInDown"><a href="/2020/06/07/Computer/" title="Computer" class="posttitle">Computer</a></h3>
        
            <p class="post-count animated fadeInDown">
                
                    <span>
                        <b class="iconfont icon-text2"></b> <i>Words count</i>
                        6.4k
                    </span>
                
                
                    <span>
                        <b class="iconfont icon-timer__s"></b> <i>Reading time</i>
                        6 mins.
                    </span>
                
                
            </p>
            
                <ul class="animated fadeInDown post-tags-list" itemprop="keywords"><li class="animated fadeInDown post-tags-list-item"><a class="animated fadeInDown post-tags-list-link" href="/tags/Computer/" rel="tag">Computer</a></li></ul>
            
        
        <div class="md-content animated fadeIn">
            
                

<ul>
<li><a href="#堆栈的区别">堆栈的区别</a></li>
<li><a href="#进程和线程">进程和线程</a><ul>
<li><a href="#什么是进程">什么是进程</a></li>
<li><a href="#什么是线程">什么是线程</a></li>
<li><a href="#区别">区别</a></li>
</ul>
</li>
<li><a href="#互联网协议">互联网协议</a><ul>
<li><a href="#实体层">实体层</a></li>
<li><a href="#链接层">链接层</a><ul>
<li><a href="#以太网协议">以太网协议</a></li>
<li><a href="#mac地址">MAC地址</a></li>
<li><a href="#广播">广播</a></li>
</ul>
</li>
<li><a href="#网络层">网络层</a><ul>
<li><a href="#ip地址">IP地址</a></li>
<li><a href="#ip数据包">IP数据包</a></li>
<li><a href="#arp协议">ARP协议</a></li>
</ul>
</li>
<li><a href="#传输层">传输层</a><ul>
<li><a href="#udp协议">UDP协议</a></li>
<li><a href="#tcp协议">TCP协议</a></li>
</ul>
</li>
<li><a href="#应用层">应用层</a></li>
</ul>
</li>
</ul>

<ol>
<li><p>栈内存存储的是局部变量而堆内存存储的是实体；</p>
</li>
<li><p>栈内存的更新速度要快于堆内存，因为局部变量的生命周期很短；</p>
</li>
<li><p>栈内存存放的变量生命周期一旦结束就会被释放，而堆内存存放的实体会被垃圾回收机制不定时的回收。</p>
</li>
</ol>
<h4 id="什么是进程"><a href="#什么是进程" class="headerlink" title="什么是进程"></a>什么是进程</h4><ul>
<li>进程是资源(CPU、内存等)分配的基本单位，它是程序执行...</li></ul>
            
            <span class="read-more"><a href="/2020/06/07/Computer/" title="Read article" class="posttitle">Read article</a> <b class="iconfont icon-arrow-right- gradient-text"></b></span>
        </div>
    </div>
</div>


<div class="post" id="post">
    <div class="post-cover animated fadeIn" style="
            background-image:
            radial-gradient(ellipse closest-side, rgba(0, 0, 0, 0.65), #100e17),
            url(/img/welcome-cover.jpg);">
    </div>
    <div class="else">
        <p class="animated fadeInDown">
            
                <a href="/categories/PHP">
                  <b>「 </b>PHP<b> 」</b>
                </a>
            
            June 05, 2020
        </p>
        <h3 class="post-title animated fadeInDown"><a href="/2020/06/05/PHP/" title="PHP" class="posttitle">PHP</a></h3>
        
            <p class="post-count animated fadeInDown">
                
                    <span>
                        <b class="iconfont icon-text2"></b> <i>Words count</i>
                        1k
                    </span>
                
                
                    <span>
                        <b class="iconfont icon-timer__s"></b> <i>Reading time</i>
                        1 mins.
                    </span>
                
                
            </p>
            
                <ul class="animated fadeInDown post-tags-list" itemprop="keywords"><li class="animated fadeInDown post-tags-list-item"><a class="animated fadeInDown post-tags-list-link" href="/tags/PHP/" rel="tag">PHP</a></li></ul>
            
        
        <div class="md-content animated fadeIn">
            
                

<ul>
<li><a href="#正则表达式">正则表达式</a></li>
</ul>


<table>
<thead>
<tr>
<th>/i</th>
<th>(忽略大小写)</th>
</tr>
</thead>
<tbody><tr>
<td>/g</td>
<td>(全文查找出现的所有匹配字符)</td>
</tr>
<tr>
<td>/m</td>
<td>(多行查找)</td>
</tr>
<tr>
<td>/gi</td>
<td>(全文查找、忽略大小写)</td>
</tr>
<tr>
<td>/ig</td>
<td>(全文查找、忽略大小写)</td>
</tr>
</tbody></table>
<pre><code>mixed preg_replace ( mixed $pattern , mixed $replacement , mixed $subject [, int $limit = -1 [, int &amp;$count ]] )
搜索 subject 中匹配 pattern 的部分， 以 replacement...</code></pre>
            
            <span class="read-more"><a href="/2020/06/05/PHP/" title="Read article" class="posttitle">Read article</a> <b class="iconfont icon-arrow-right- gradient-text"></b></span>
        </div>
    </div>
</div>


    </div>
    
</div>
<div id="preview"></div>

    <div id="back-to-top" class="animated fadeIn faster">
        <div class="flow"></div>
        <span class="percentage animated fadeIn faster">0%</span>
        <span class="iconfont icon-top02 animated fadeIn faster"></span>
    </div>
</body>
<footer>
    <p class="copyright" id="copyright">
        &copy; 2020
        <span class="gradient-text">
            weifan
        </span>.
        Powered by <a href="http://hexo.io/" title="Hexo" target="_blank" rel="noopener">Hexo</a>
        Theme
        <span class="gradient-text">
            <a href="https://github.com/TriDiamond/hexo-theme-obsidian" title="Obsidian" target="_blank" rel="noopener">Obsidian</a>
        </span>
        <small><a href="https://github.com/TriDiamond/hexo-theme-obsidian/blob/master/CHANGELOG.md" title="v1.4.3" target="_blank" rel="noopener">v1.4.3</a></small>
    </p>
</footer>

<script type="text/javascript" src="https://cdn.bootcss.com/mathjax/2.7.6/MathJax.js?config=TeX-AMS-MML_HTMLorMML">
</script>
<script>
  MathJax.Hub.Config({
    "HTML-CSS": {
      preferredFont: "TeX",
      availableFonts: ["STIX", "TeX"],
      linebreaks: {
        automatic: true
      },
      EqnChunk: (MathJax.Hub.Browser.isMobile ? 10 : 50)
    },
    tex2jax: {
      inlineMath: [
        ["$", "$"],
        ["\\(", "\\)"]
      ],
      processEscapes: true,
      ignoreClass: "tex2jax_ignore|dno",
      skipTags: ['script', 'noscript', 'style', 'textarea', 'pre', 'code']
    },
    TeX: {
      noUndefined: {
        attributes: {
          mathcolor: "red",
          mathbackground: "#FFEEEE",
          mathsize: "90%"
        }
      },
      Macros: {
        href: "{}"
      }
    },
    messageStyle: "none"
  });
</script>
<script>
  function initialMathJax() {
    MathJax.Hub.Queue(function () {
      var all = MathJax.Hub.getAllJax(),
        i;
      // console.log(all);
      for (i = 0; i < all.length; i += 1) {
        console.log(all[i].SourceElement().parentNode)
        all[i].SourceElement().parentNode.className += ' has-jax';
      }
    });
  }

  function reprocessMathJax() {
    if (typeof MathJax !== 'undefined') {
      MathJax.Hub.Queue(["Typeset", MathJax.Hub]);
    }
  }
</script>



    
<link rel="stylesheet" href="//cdn.bootcss.com/gitalk/1.5.0/gitalk.min.css">

    
<script src="//cdn.bootcss.com/gitalk/1.5.0/gitalk.min.js"></script>



<script src="//cdnjs.cloudflare.com/ajax/libs/jquery/3.4.1/jquery.min.js"></script>
<script src="/js/plugin.js"></script>
<script src="/js/obsidian.js"></script>
<script src="/js/jquery.truncate.js"></script>
<script src="/js/search.js"></script>


<script src="//cdn.bootcss.com/typed.js/2.0.10/typed.min.js"></script>


<script src="//cdn.bootcss.com/blueimp-md5/2.12.0/js/md5.min.js"></script>


<script src="//cdnjs.cloudflare.com/ajax/libs/social-share.js/1.0.16/js/social-share.min.js"></script>


<script src="https://cdn.bootcss.com/codemirror/5.48.4/codemirror.min.js"></script>

    
<script src="//cdn.bootcss.com/codemirror/5.48.4/mode/javascript/javascript.min.js"></script>


    
<script src="//cdn.bootcss.com/codemirror/5.48.4/mode/css/css.min.js"></script>


    
<script src="//cdn.bootcss.com/codemirror/5.48.4/mode/xml/xml.min.js"></script>


    
<script src="//cdn.bootcss.com/codemirror/5.48.4/mode/htmlmixed/htmlmixed.min.js"></script>


    
<script src="//cdn.bootcss.com/codemirror/5.48.4/mode/clike/clike.min.js"></script>


    
<script src="//cdn.bootcss.com/codemirror/5.48.4/mode/php/php.min.js"></script>


    
<script src="//cdn.bootcss.com/codemirror/5.48.4/mode/shell/shell.min.js"></script>


    
<script src="//cdn.bootcss.com/codemirror/5.48.4/mode/python/python.min.js"></script>




    
<script src="/js/busuanzi.min.js"></script>

    <script>
        $(document).ready(function () {
            if ($('span[id^="busuanzi_"]').length) {
                initialBusuanzi();
            }
        });
    </script>



<link rel="stylesheet" href="//cdn.bootcss.com/photoswipe/4.1.3/photoswipe.min.css">
<link rel="stylesheet" href="//cdn.bootcss.com/photoswipe/4.1.3/default-skin/default-skin.min.css">


<script src="//cdn.bootcss.com/photoswipe/4.1.3/photoswipe.min.js"></script>
<script src="//cdn.bootcss.com/photoswipe/4.1.3/photoswipe-ui-default.min.js"></script>


<!-- Root element of PhotoSwipe. Must have class pswp. -->
<div class="pswp" tabindex="-1" role="dialog" aria-hidden="true">
    <!-- Background of PhotoSwipe. 
         It's a separate element as animating opacity is faster than rgba(). -->
    <div class="pswp__bg"></div>
    <!-- Slides wrapper with overflow:hidden. -->
    <div class="pswp__scroll-wrap">
        <!-- Container that holds slides. 
            PhotoSwipe keeps only 3 of them in the DOM to save memory.
            Don't modify these 3 pswp__item elements, data is added later on. -->
        <div class="pswp__container">
            <div class="pswp__item"></div>
            <div class="pswp__item"></div>
            <div class="pswp__item"></div>
        </div>
        <!-- Default (PhotoSwipeUI_Default) interface on top of sliding area. Can be changed. -->
        <div class="pswp__ui pswp__ui--hidden">
            <div class="pswp__top-bar">
                <!--  Controls are self-explanatory. Order can be changed. -->
                <div class="pswp__counter"></div>
                <button class="pswp__button pswp__button--close" title="Close (Esc)"></button>
                <button class="pswp__button pswp__button--share" title="Share"></button>
                <button class="pswp__button pswp__button--fs" title="Toggle fullscreen"></button>
                <button class="pswp__button pswp__button--zoom" title="Zoom in/out"></button>
                <!-- Preloader demo http://codepen.io/dimsemenov/pen/yyBWoR -->
                <!-- element will get class pswp__preloader--active when preloader is running -->
                <div class="pswp__preloader">
                    <div class="pswp__preloader__icn">
                      <div class="pswp__preloader__cut">
                        <div class="pswp__preloader__donut"></div>
                      </div>
                    </div>
                </div>
            </div>
            <div class="pswp__share-modal pswp__share-modal--hidden pswp__single-tap">
                <div class="pswp__share-tooltip"></div> 
            </div>
            <button class="pswp__button pswp__button--arrow--left" title="Previous (arrow left)">
            </button>
            <button class="pswp__button pswp__button--arrow--right" title="Next (arrow right)">
            </button>
            <div class="pswp__caption">
                <div class="pswp__caption__center"></div>
            </div>
        </div>
    </div>
</div>



    <!-- Global site tag (gtag.js) - Google Analytics -->
    <script async src="//www.googletagmanager.com/gtag/js?id=UA-149874671-1"></script>
    <script>
        window.dataLayer = window.dataLayer || [];
        function gtag(){dataLayer.push(arguments);}
        gtag('js', new Date());

        gtag('config', 'UA-149874671-1');
    </script>





<script>
    function initialTyped () {
        var typedTextEl = $('.typed-text');
        if (typedTextEl && typedTextEl.length > 0) {
            var typed = new Typed('.typed-text', {
                strings: ["Think like an artist, develop like an artisan", "艺术家思维去思考问题，工匠创造精神去开发"],
                typeSpeed: 90,
                loop: true,
                loopCount: Infinity,
                backSpeed: 20,
            });
        }
    }

    if ($('.article-header') && $('.article-header').length) {
        $(document).ready(function () {
            initialTyped();
        });
    }
</script>




</html>
